package com.liholin.springboot.sample.bean;

import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;

@Data
public class LoginBean {
    @NotBlank(message = "请输入用户名")
    private String userName;
    @NotBlank(message = "请输入密码")
    @Length(message = "密码范围为{min}到{max}之间", min = 6,max = 30)
    private String passWord;

//    @Range(message = "年龄范围为{min}到{max}之间", min = 1,max = 100)
//    private int age;
//    @Size(message = "选择的数量不能超过{max}",max = 5)
//    private int num;
//    @Email(message = "邮箱格式错误")
//    private String email;
}
